import {createStore, applyMiddleware, combineReducers} from 'redux';
//一. 安装并导入 thunk,  redux 中导入applyMiddleware
import thunk from 'redux-thunk';
//导入 ZanReducer 函数
import ZanReducer from './reducers/ZanReducer';
//导入 CollReducer 函数
import CollReducer from './reducers/CollReducer';
// combineReducers 合并. 将 redux 中保存的数据变为一个对象
let rootReducer = combineReducers({
    zan: ZanReducer,
    coll: CollReducer
});

let store = createStore(rootReducer, applyMiddleware(thunk));


export default store;





